<?php

namespace App\Models;

use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;

class Minappimage extends Model
{
    protected $table = 'minapp_image';
    protected $primaryKey = 'id';
    
    public static function miniappImageList($appid)
    {
        return self::select("image")->where("appid",$appid)->get();
    }

    public static function createMiniappImage($images)
    {
        return self::insert($images);
    }

    public static function deleteMiniappImage($appid)
    {
        return self::where("appid",$appid)->delete();
    }
}